﻿{layout:default} {class:Shop.Supplier.Config.indeximage}
<lbhead>
    <title><%=node.Name%>--<%=site.title%></title>
</lbhead>
<lbpath>
<div class="tools">
    <ul>
        <%if (PageReturnMsg == ""){%>
        <li class="add"><a href="javascript:void(0);" onclick="Edit(0)"><b></b><span><%=Tag("添加")%></span></a></li>
        <li class="del"><a href="javascript:void(0);" onclick="Page_Del();"><b></b><span><%=Tag("删除")%></span></a></li>
        <%}%>
        <li class="name"><span id="navIgation"><%=Tag("当前位置")%>：<a href="<%=site.AdminPath %>/Ajax/ajax_admin.aspx?__Action=MenuJump&pid=0"><%=Tag("管理首页")%></a> > <%=node.Name%></span></li>
    </ul>
</div>
</lbpath>
<lbbody>
    <table id="list" class="datalist">
        <tr class="title">
            <th style="width: 40px" class="selectAll">
                <a href="javascript:void(0);" onclick="$('input[name=\'ids\']').attr('checked',!$(this).attr('checked'));$(this).attr('checked',!$(this).attr('checked'));">
                    <%=Tag("全选")%></a>
            </th>
            <th style="width: 100px">
                <%=Tag("图片")%>
            </th>
            <th style="width: 200px">
                <%=Tag("名称")%>
            </th>
            <th style="width: 200px">
                <%=Tag("链接")%>
            </th>
            <th style="width: 80px">
                <%=Tag("排序")%>
            </th>
            <th style="width: 130px">
                <%=Tag("时间")%>
            </th>
            <th>
                <%=Tag("操作")%>
            </th>
        </tr>
        <div id="listinfo" style="display: none;">
            <%foreach (Shop.Model.Lebi_Page model in pages)
              {%>
            <tr class="list" ondblclick="Edit(<%=model.id %>);">
                <td style="text-align:center">
                    <input type="checkbox" name="ids" del="true" value="<%=model.id %>" />
                </td>
                <td>
                    <img src="<%=model.ImageOriginal%>" height="60" />
                </td>
               
                <td>
                    <%=model.Name%>
                </td>
                 <td>
                    <%=model.url%>
                </td>
                <td>
                    <%=model.Sort%>
                </td>
                <td>
                    <%=model.Time_Add%>
                </td>
                <td>
                    <a href="javascript:void(0);" onclick="Edit(<%=model.id %>)">
                        <%=Tag("编辑")%></a>
                </td>
            </tr>
            <%} %>
    </table>
    <script type="text/javascript">
        function Page_Del(id) {
            if (!confirm("<%=Tag("确认要删除吗？")%>"))
                return false;
            var postData = GetFormJsonData("del");
            var url = "<%=site.AdminPath %>/ajax/ajax_config.aspx?__Action=indeximage_Del";
            RequestAjax(url,postData,function(){MsgBox(1, "<%=Tag("操作成功")%>", "?")});
        }
        function Edit(id) {
            window.location = "indeximage_edit.aspx?id="+id;
        }
    </script>
</lbbody>
<lbbottom>
    <div class="bottom" id="body_bottom">
        <%=PageString%></div>
</lbbottom>